#ifndef UCWEB_IMAGE_H
#define UCWEB_IMAGE_H

//#include "/home/nemo/qingm/lib/include/GraphicsMagick/Magick++.h"
//#include <GraphicsMagick/Magick++.h>
#include <Magick++.h>
extern "C" {
#include <jpeglib.h>
}
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <iostream>
#include <sys/time.h>
#include <time.h>
#include "webp.h"
/*
#include <decode.h>
#include <encode.h>
#include <types.h>
*/
using namespace std;
using namespace Magick;

typedef struct info
{
  int width;
  int height;
   int stride;
  uint8_t* rgb;

  info():width(0), height(0), stride(0), rgb(NULL)
  {

  }

  ~info()
  {
    if(rgb) {
      free(rgb);
    }
  }

}jpeg_image_info_byjpegc;
/*
class ucwebImage
{
public:
  ucwebImage(){}

  virtual ~ucwebImage(){}

  virtual int DecompressByGm() {};
  virtual int DecompressByJpeglib();

  virtual int ResizeByWebp(){}
  virtual int ResizeByGm(){}

  virtual int CompressByGm(){}
  virtual int CompressByWebp(bool resize){}
  virtual int CompressByJpeg(){}

  virtual int InitWebp(){}
  virtual int ProduceWebpInfoFromJpeg(){}
  virtual int ProduceWebpInfoFromGm(){}
  virtual int ProduceGmInfoFromJpeg(){}

  virtual int WriteResult(const char* data, size_t data_size, const char *filename){}
  
  virtual int DecomGmResizeGm(){}
  virtual int DecomGmResizeWebp(){}
  virtual int DecomJpegResizeGm(){}
  virtual int DecomJpegResizeWebp(){}

  virtual int libjpegGMWebP(){}
};
*/

#endif   /* UCWEB_IMAGE_H_*/
